package com.globagames.jungleonline.model
{
	import __AS3__.vec.Vector;
	
	//import com.globagames.core.business.UserConnexionManager;
	//import com.globagames.core.model.ModelLocator;
	
	import kaaengine.core.SceneManager;
	import kaaengine.loaders.ObjectsLoader;
	import kaaengine.objects.ObjectsManager;
	
	import mx.collections.ArrayCollection;
	
	[Bindable]
	public class JungleModelLocator
	{
		private static var modelLocator:JungleModelLocator;
		
		public function JungleModelLocator()
		{			
			if(modelLocator!=null)throw new Error("Only one JungleModelLocator should be instancied !");
			communicationMessage = "chargement...";	
			random = Math.random();			
		}
		public static function getInstance():JungleModelLocator {
			if(modelLocator==null) modelLocator = new JungleModelLocator();
			return modelLocator;
		}
		public var ol:ObjectsLoader = new ObjectsLoader("assets/objects/");
				
		public var opponentPlayer:Player;
		public var currentPlayer:Player;
		public var currentTurn:String="UNDEFINED";
		public var communicationMessage:String;			
		public var sm:SceneManager = new SceneManager();		
		public var om:ObjectsManager;
		public var board:Vector.<int>;	
		public var isOnline:Boolean = false;
		
		//public var userConnexionManager:UserConnexionManager;
		public var random:Number;
		public var animals:ArrayCollection;
		public var opponentAnimals:ArrayCollection;
	}
}